﻿using ATM.Entities;
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Windows.Forms;

namespace ATMSystem
{
    public partial class frmReceiveName : Form
    {
        private Account passAcc;
        private Card passCard;
 
        public frmReceiveName()
        {
            InitializeComponent();
        }

        public frmReceiveName(Account acc,Card card)
        {
            InitializeComponent();
            passAcc = acc;
            passCard = card;
        }

        public string AccCusID;
        public string AccReceiveID;
        public string nameReceiveID;
        private void frmReceiveName_Load(object sender, EventArgs e)
        {
            lblThongTin.Text="Người nhận: "+ nameReceiveID;
            txtReceiveID.Text=AccReceiveID;
        }


        private void txtReceiveID_KeyPress(object sender, KeyPressEventArgs e)
        {
            e.Handled = true;
        }

        private void btn_Cancle_Click(object sender, EventArgs e)
        {
            this.Close();
        }

        //enter
        private void button6_Click(object sender, EventArgs e)
        {
            frmAmountTransfer frm = new frmAmountTransfer(passAcc,passCard);
            frm.Show();
            frm.AccCusID = AccCusID;
            frm.accReceiveID = AccReceiveID;
            this.Visible = false;
        }

    }
}
